<?php
/**
 * The loop that displays a single post.
 *
 */
$options_adword = new leeproOptions();
$options = $options_adword->getOptions();
?>
<?php if (have_posts()) : the_post(); update_post_caches($posts); ?>
	<div class="item-page">
	<h2 class="post_title"><?php the_title();?></h2>
		<p class="articleinfo">
			<span class="modifydate">Last Updated on &nbsp;<?php the_time(__('M d, Y', 'leepro_adword')) ?></span>

			<?php if ($options['author']) : ?>|&nbsp;<span class="createdby">Written by &nbsp;<?php the_author_posts_link(); ?></span><?php endif; ?>
			<?php edit_post_link(__('Edit', 'leepro_adword'), '<span class="editpost">', '</span>'); ?>
			<?php if ($comments || comments_open()) : ?>
			&nbsp;|&nbsp;<span class="addcomment"><a href="#respond"><?php _e('Leave a comment', 'leepro_adword'); ?></a></span>
			&nbsp;|&nbsp;<span class="comments"><a href="#comments"><?php _e('Go to comments', 'leepro_adword'); ?></a></span>
			<?php endif; ?>
		</p>

		<?php the_content();?>
		<div class="under">
		<?php 

		if ($options['categories']) : ?><span class="categories"><?php _e('Categories: ', 'leepro_adword'); ?></span><span><?php the_category(', '); ?></span><?php endif; ?>
		<?php if ($options['tags']) : ?><span class="tags"><?php _e('Tags: ', 'leepro_adword'); ?></span><span><?php the_tags('', ', ', ''); ?></span><?php endif; ?>
		</div>
		<?php include('templates/comments.php'); ?>

		<div id="postnavi">
		<span class="prev"><?php next_post_link('%link') ?></span>
		<span class="next"><?php previous_post_link('%link') ?></span>
		<div class="fixed"></div>
		</div>
	</div>
	<?php else : ?>
		<div class="errorbox">
			<?php _e('Sorry, no posts matched your criteria.', 'leepro_adword'); ?>
		</div>
<?php endif; ?>